﻿using SalesPages.DomainModel.DomainModel;
using SalesPages.DomainModel.ViewModel;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;

namespace SalesPages.Infrastructure.IManager
{
    public interface IUserManager
    {
        bool Add(E1SysUser entity);
        bool Update(E1SysUser entity);
        bool Delete(string id);
        List<E1SysUser> GetAll();

        E1SysUser GetEntity(string id);
        IPagedList<E1SysUser> SearchErpSysUser(Expression<Func<E1SysUser, bool>> filterExpression, PageCondition pageCondition);
        E1SysLogin GetLoginAccount(string id);      
        bool AddLoginAccount(E1SysLogin login);
        bool UpdateLoginAccount(E1SysLogin login);
        E1SysLogin Login(LoginModel model);
        E1SysLogin Login(string userId, string password);
        E1SysLogin GetLoginByUserName(string username);
        CurrentUser GetCurrentUserData(string userName);
    }
}
